package com.px.service.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.px.common.annotation.Excel;
import com.px.common.core.domain.BaseEntity;

/**
 * 推荐文章对象 t_recommend_articles
 *
 * @author 品讯科技
 * @date 2024-08
 */
public class RecommendArticles extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    private Long id;

    /**
     * 文章标题
     */
    @Excel(name = "文章标题")
    private String title;

    /**
     * 文章内容
     */
    @Excel(name = "文章内容")
    private String content;

    /**
     * 封面图片地址
     */
    @Excel(name = "封面图片地址")
    private String imageUrl;

    /**
     * 文章类型
     */
    @Excel(name = "文章类型")
    private Long type;

    /**
     * 状态（-=1-禁用，0-未审核，1-正常）
     */
    @Excel(name = "状态", readConverterExp = "-1=禁用,0=未审核,1=正常")
    private Long status;

    /**
     * 类型标签名称
     */
    private String typeLabel;

    public String getTypeLabel() {
        return typeLabel == null ? "" : typeLabel;
    }

    public void setTypeLabel(String typeLabel) {
        this.typeLabel = typeLabel;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getTitle() {
        return title;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getContent() {
        return content;
    }

    public String getImageUrl() {
        return imageUrl == null ? "" : imageUrl;
    }

    public void setImageUrl(String imageUrl) {
        this.imageUrl = imageUrl;
    }

    public void setType(Long type) {
        this.type = type;
    }

    public Long getType() {
        return type;
    }

    public void setStatus(Long status) {
        this.status = status;
    }

    public Long getStatus() {
        return status;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("title", getTitle())
                .append("content", getContent())
                .append("imageUrl", getImageUrl())
                .append("type", getType())
                .append("status", getStatus())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .toString();
    }
}
